<%@ page isErrorPage="true" %>
<%@ page pageEncoding="utf-8"%>
<%@ include file="/common/taglibs.jsp"%> 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>提示信息</title>
<style type="text/css">
<!--
body {
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
}
-->
</style>
<link rel="stylesheet" type="text/css" media="all"	href="<c:url value='/styles/layout.css'/>" />
<script type="text/javascript">
<!--


function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
//-->
</script>
<link href="./styles/sasis/css.css" rel="stylesheet" type="text/css" />
</head>

<body>
<table width="99%" border="0" cellspacing="0" cellpadding="0" align=center>
<tr> 
     <td class="home-content-title"><img src="images/home_ico_listTitle.gif" width="22" height="20" align="absmiddle"/>错误提示</td>
</tr>
 
 <tr> 
    <td valign="top"> 
    
    	<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
        <tr> 
          <td class="home-table-topline"> </td>
        </tr>
        <tr> 
          <td class="home-table-leftline">

				 <%-- Error Messages --%>
                <logic:messagesPresent>
                    <logic:present name="error">
                    <div class="error">
                        <html:messages id="error">
                            <c:out value="${error}" escapeXml="false"/><br/>
                        </html:messages>
                    </div>
                    </logic:present>
                </logic:messagesPresent>
                
                <logic:notPresent name="error"> 
                	<% if (exception == null) { %>
					可能是没加上配置，导致前台与后台断开，<br>
					请查询<1>applicationContext-ibatis.xml,<br>
					<2>applicationContext-service.xml,<br>
					<3>sql-map-config.xml<br>
					<4>struts-config-*.xml<br>
					<5>JSPs<br>
					<%}%>
                </logic:notPresent>
 			<% 
 			Exception ex = (Exception)request.getAttribute("com.sasis.ERROR");
 			    	 
 				if (null!=ex) {  
	 			      Exception ex1 = (Exception) ex.getCause();
					  if(null!=ex1){
	  					  	out.println(ex+"<br><div>错误详细请点击连接:<a href='#' onclick='javascript:displayError();'><font color='red'><<详细错误</font></a></div><br>");
					  }else  	out.println(ex+"<br><div>错误详细请点击连接:<a href='#' onclick='javascript:displayError();'><<详细错误</a></div><br>");
	
				%>
                <%}else{%>
                <pre><%  
		                out.println(ex+"<br><div>错误详细请点击连接:<a href='#' onclick='javascript:displayError();'><<详细错误</a></div><br>");
                    %></pre>
                <%}%>
                
				<!--详细错误信息显示 add by kellen-->                
				<table id="errorBar" style="display:none"><tr><td>	
					<%((Exception)request.getAttribute("com.sasis.ERROR"))
                                           .printStackTrace(new java.io.PrintWriter(out));%>
				</td></tr></table>                                           

          </td>
        </tr>
        <tr> 
          <td height="12"> <table width="100%" border="0" cellspacing="0" cellpadding="0">
          
              <tr> 
                <td class="home-table-bottom-left">&nbsp;</td>
                <td class="home-table-bottom-bg">&nbsp;</td>
                <td class="home-table-bottom-right">&nbsp;</td>
              </tr>
            </table></td>
        </tr>
      </table></td>
  </tr>
  <tr> 
    <td height="10">&nbsp;</td>
  </tr>
</table>


 
</body>
</html>
<script>
	function displayError(){
		if(document.all("errorBar").style.display==''){
			document.all("errorBar").style.display='none';
		}else {
			document.all("errorBar").style.display='';
		}
		
	}
</script>
